package com.y.config.exception;

import com.y.entity.vo.RHttpStatusEnum;

/**
 * @author: Yjh
 */
public class AccountLoginException extends  RuntimeException {


    private Integer code;
    private String message;


    public AccountLoginException(Integer code, String message) {
        this.code = code;
        this.message = message;
    }

    public AccountLoginException(String message) {
        this.message = message;
    }

    public AccountLoginException(RHttpStatusEnum rHttpStatusEnum) {
        this.code = rHttpStatusEnum.getCode();
        this.message = rHttpStatusEnum.getMessage();
    }

    @Override
    public String getMessage() {
        return message;
    }

    public Integer getCode() {
        return code;
    }

}
